package com.ruoyi.answer.domain.bo;

import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.validate.AddGroup;
import com.ruoyi.common.core.validate.EditGroup;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.*;

import java.util.Date;

import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 试卷管理业务对象 exam_paper
 *
 * @author kun_er
 * @date 2022-08-16
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class ExamPaperBo extends BaseEntity {

    /**
     * 自动编号
     */
    @NotNull(message = "自动编号不能为空", groups = { EditGroup.class })
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 所属课程id
     */
    @NotNull(message = "所属课程id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long trainingId;

    /**
     * 试卷类型（A,B,C）
     */
    @NotBlank(message = "试卷类型（A,B,C）不能为空", groups = { AddGroup.class, EditGroup.class })
    private String paperType;

    /**
     * 试卷名称
     */
    @NotBlank(message = "试卷名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String paperName;
    /**
     * 考试时间
     */
    @NotNull(message = "考试时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date startTime;

    /**
     * 阅卷人账户
     */
    @NotBlank(message = "阅卷人账户不能为空", groups = { AddGroup.class, EditGroup.class })
    private String markingAccount;

    /**
     * 试卷分数
     */
    @NotNull(message = "试卷分数不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long totalScore;

    /**
     * 及格分数
     */
    @NotNull(message = "及格分数不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long passingScore;

    /**
     * 考试时间
     */
    @NotNull(message = "考试时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long examDuration;

    /**
     * 试卷状态
     */
    @NotNull(message = "试卷状态不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long state;


}
